(use-modules (netlist attrib compare))

(test-begin "attrib:refdes<?")
(test-assert (refdes<? "DA0" "DA1"))
(test-assert (refdes<? "3R5" "R1"))
(test-assert (refdes<? "R05" "R5"))
(test-assert (refdes<? "R005" "R05"))
(test-assert (refdes<? "00R1" "0R1"))
(test-assert (refdes<? "R5" "X5"))
(test-assert (refdes<? "40R5" "40R5A10"))
(test-assert (refdes<? "40R5" "40r5"))
(test-end "attrib:refdes<?")

(test-begin "attrib:value<?")
(test-assert (value<? "100" "200"))
(test-assert (value<? "100" "20k"))
(test-assert (value<? "1p" "1n"))
(test-assert (value<? "1n" "1u"))
(test-assert (value<? "1u" "1m"))
(test-assert (value<? "1m" "1"))
(test-assert (value<? "1" "1k"))
(test-assert (value<? "1k" "1M"))
(test-assert (value<? "1M" "1G"))
(test-assert (value<? "1G" "1T"))
(test-end "attrib:value<?")
